package models;

import com.alibaba.fastjson.JSONArray;

import java.util.HashMap;

/**
 * Created by yangxianming on 2021/3/22.
 */
public class User {
    public String getUsername() {
        return username;
    }

    public void setUsername(String username) {
        this.username = username;
    }

    public String getSessionId() {
        return sessionId;
    }

    public void setSessionId(String sessionId) {
        this.sessionId = sessionId;
    }

    public User getUser(String username) {
        return userList.get(username);
    }

    public void setUserList(User user) {
        userList.put(user.getUsername(), user);
    }

    public JSONArray getPower() {
        return power;
    }

    public void setPower(JSONArray power) {
        this.power = power;
    }

    private String username;
    private JSONArray power;
    private String sessionId;
    private HashMap<String, User> userList = new HashMap<String, User>();
}
